package com.ztgf.commodity.models.service;

import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.IService;
import com.ztgf.commodity.models.bo.AttributesQueryBO;
import com.ztgf.commodity.models.bo.CommoditySpecificationBO;
import com.ztgf.commodity.models.bo.CommoditySpecificationSaveBO;
import com.ztgf.commodity.models.dto.CommoditySpecificationDTO;
import com.ztgf.commodity.models.vo.CommoditySpecificationTreeVO;
import com.ztgf.commodity.models.vo.CommoditySpecificationVO;
import com.ztgf.common.constant.Result;

import java.io.Serializable;
import java.util.List;

/**
 * author: chenyu.wang
 * date: 2020-05-26 14:23
 * Description:商品规格
 */
public interface ICommoditySpecificationService extends IService<CommoditySpecificationDTO> {

    /**
     * description:添加商品规格
     * param: [bo]
     * author: chenyu.wang
     * date: 2020-05-26
     * return: boolean
     */
    boolean add(CommoditySpecificationSaveBO bo);

    /**
     * description:逻辑删除/恢复商品规格
     * param: [id]
     * author: chenyu.wang
     * date: 2020-05-26
     * return: boolean
     */
    boolean deleteLogic(Long id);

    /**
     * description: id查询
     * param: [id]
     * author: chenyu.wang
     * date: 2020-05-28
     * return: com.ztgf.commodity.models.dto.CommoditySpecificationDTO
     */
    CommoditySpecificationVO getById(Long id);

    /**
     * description: 查询规格属性列表
     * param: [bo]
     * author: chenyu.wang
     * date: 2020-07-09
     * return: com.baomidou.mybatisplus.plugins.Page<com.ztgf.commodity.models.vo.CommoditySpecificationVO>
     */
    Page<CommoditySpecificationVO> queryPageList(AttributesQueryBO bo);

    Result<List<String>> newAdd(String object);

    Result<List<String>> newUpdate(String object);

    /**
     * @Description: 查询规格信息新
     * @Author: chenyu.wang
     * @Params: [bo]
     * @Date: 2020.11.04 11:29
     */
    Page<CommoditySpecificationVO> newQueryPageList(AttributesQueryBO bo);

}
